/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * PanelPaso1.java
 *
 * Created on 11-nov-2009, 12:48:49
 */
package pestañas;

import dialogos.DialogoMetodoMPF;
import java.awt.Color;
import java.awt.event.ItemEvent;
import javax.swing.JFrame;
import javax.swing.JProgressBar;

import javax.swing.JRadioButton;
import javax.swing.JTextField;
import net.java.balloontip.BalloonTip;
import net.java.balloontip.styles.MinimalBalloonStyle;
import net.java.balloontip.utils.TimingUtils;
import utilidades.ValidaBarras;
import utilidades.ValoresMetodologiaEstimacion;
import vistas.VistaPrincipal;

/**
 *
 * @author Shidobu
 */
public class PanelPaso1 extends javax.swing.JPanel {
	VistaPrincipal vista;
	JProgressBar barraProgreso;
	boolean cambioPeriodoEntrega;
	boolean cambioLugarEvaluacion;
	boolean cambioTamañoSoftware;

	private ValoresMetodologiaEstimacion vme = new ValoresMetodologiaEstimacion ();
	// Fin valores de la metodología

	/** Creates new form PanelPaso1 */
	public PanelPaso1 () {
		initComponents ();
	}

    public JTextField getjTextFieldHorasTamañoSoftware() {
        return jTextFieldHorasTamañoSoftware;
    }

    public JTextField getjTextFieldTotalUsuarios() {
        return jTextFieldTotalUsuarios;
    }

    public JTextField getjTextFieldFactorTiempoEntrega() {
        return jTextFieldFactorTiempoEntrega;
    }

    public JTextField getjTextFieldHorasUsuariosEvaluadores() {
        return jTextFieldHorasUsuariosEvaluadores;
    }

    public JTextField getJTextFieldUCE() {
        return jTextFieldUCE;
    }

    public JTextField getJTextFieldUEX() {
        return jTextFieldUEX;
    }

    public JTextField getJTextFieldUNCE() {
        return jTextFieldUNCE;
    }

    public JRadioButton getJRadioButtonEmpresa() {
        return jRadioButtonEmpresa;
    }

    public JRadioButton getJRadioButtonEvaluador() {
        return jRadioButtonEvaluador;
    }

    public JRadioButton getJRadioButtonLugarArrendado() {
        return jRadioButtonLugarArrendado;
    }

    public JRadioButton getJRadioButtonLugarEmpresa() {
        return jRadioButtonLugarEmpresa;
    }

    public JRadioButton getJRadioButtonTamañoSoftwareGrande() {
        return jRadioButtonTamañoSoftwareGrande;
    }

    public JRadioButton getJRadioButtonTamañoSoftwareMedio() {
        return jRadioButtonTamañoSoftwareMedio;
    }

    public JRadioButton getJRadioButtonTamañoSoftwarePequeño() {
        return jRadioButtonTamañoSoftwarePequeño;
    }

    public JTextField getJTextFieldDiasEmpresa() {
        return jTextFieldDiasEmpresa;
    }

    public JTextField getJTextFieldDiasEvaluador() {
        return jTextFieldDiasEvaluador;
    }

    public JTextField getJTextFieldFactorTiempoEntrega() {
        return jTextFieldFactorTiempoEntrega;
    }

    public JTextField getJTextFieldHorasLugarEvaluacion() {
        return jTextFieldHorasLugarEvaluacion;
    }

    public JTextField getJTextFieldHorasTamañoSoftware() {
        return jTextFieldHorasTamañoSoftware;
    }

    public JTextField getJTextFieldHorasUsuariosEvaluadores() {
        return jTextFieldHorasUsuariosEvaluadores;
    }

    public JTextField getJTextFieldNumeroModulosMedianos() {
        return jTextFieldNumeroModulosMedianos;
    }

    public JTextField getJTextFieldNumeroModulosPequeños() {
        return jTextFieldNumeroModulosPequeños;
    }

    public JTextField getJTextFieldTotalUsuarios() {
        return jTextFieldTotalUsuarios;
    }

    public JRadioButton getjRadioButtonEmpresa() {
        return jRadioButtonEmpresa;
    }

    public JRadioButton getjRadioButtonLugarArrendado() {
        return jRadioButtonLugarArrendado;
    }

    public JRadioButton getjRadioButtonLugarEmpresa() {
        return jRadioButtonLugarEmpresa;
    }


    

	public void setBarraProgreso (JProgressBar barraProgreso) {
		this.barraProgreso = barraProgreso;
		/*Barra*/
		jTextFieldUCE.addKeyListener (new ValidaBarras (jTextFieldUCE, barraProgreso));
		jTextFieldUNCE.addKeyListener (new ValidaBarras (jTextFieldUNCE, barraProgreso));
		jTextFieldUEX.addKeyListener (new ValidaBarras (jTextFieldUEX, barraProgreso));
		jTextFieldNumeroModulosPequeños.addKeyListener (new ValidaBarras (jTextFieldNumeroModulosPequeños, barraProgreso));
		jTextFieldNumeroModulosMedianos.addKeyListener (new ValidaBarras (jTextFieldNumeroModulosMedianos, barraProgreso));
		jTextFieldDiasEmpresa.addKeyListener (new ValidaBarras (jTextFieldDiasEmpresa, barraProgreso));
		jTextFieldDiasEvaluador.addKeyListener (new ValidaBarras (jTextFieldDiasEvaluador, barraProgreso));
	}

	public void calculaHorasTamañoSoftware () {
		if (jRadioButtonTamañoSoftwarePequeño.isSelected ()) {
			jTextFieldHorasTamañoSoftware.setText (String.valueOf (vme.getHorasPorSoftwarePequeño ()));
		}
		if (jRadioButtonTamañoSoftwareMedio.isSelected ()) {
			jTextFieldHorasTamañoSoftware.setText (String.valueOf (vme.getHorasPorSoftwareMediano ()));
		}
		if (jRadioButtonTamañoSoftwareGrande.isSelected ()) {
			int numeroModulosPequeños = 0;
			int numeroModulosMedianos = 0;
			if (!jTextFieldNumeroModulosPequeños.getText ().equals ("")) {
				numeroModulosPequeños = Integer.parseInt (jTextFieldNumeroModulosPequeños.getText ());
			}
			if (!jTextFieldNumeroModulosMedianos.getText ().equals ("")) {
				numeroModulosMedianos = Integer.parseInt (jTextFieldNumeroModulosMedianos.getText ());
			}

			jTextFieldHorasTamañoSoftware.setText (String.valueOf ((numeroModulosPequeños *
																	vme.getHorasPorSoftwarePequeño ()) + (numeroModulosMedianos * vme.getHorasPorSoftwareMediano ())));
		}
	}

	public void calculaHorasUsuariosEvaluadores () {
		if (!jTextFieldUNCE.getText ().equals ("")) {
			jTextFieldHorasUsuariosEvaluadores.setText (String.valueOf (vme.getAumentoHorasPorModalidadLugarEvaluacion ()));
		}
		else {
			if (!jTextFieldUEX.getText ().equals ("")) {
				jTextFieldHorasUsuariosEvaluadores.setText ("*8");
			}
			else {
				jTextFieldHorasUsuariosEvaluadores.setText ("0");
			}
		}
	}

	public void calculaTotalUsuarios () {
		int contador = 0;

		if (!jTextFieldUCE.getText ().equals ("")) {
			contador += Integer.parseInt (jTextFieldUCE.getText ());
		}
		if (!jTextFieldUNCE.getText ().equals ("")) {
			contador += Integer.parseInt (jTextFieldUNCE.getText ());
		}
		if (!jTextFieldUEX.getText ().equals ("")) {
			contador += Integer.parseInt (jTextFieldUEX.getText ());
		}
		jTextFieldTotalUsuarios.setText (String.valueOf (contador));
	}

	public void calculaHorasLugarEvaluacion () {
		if (jRadioButtonLugarArrendado.isSelected ()) {
			jTextFieldHorasLugarEvaluacion.setText (String.valueOf (vme.getAumentoHorasPorModalidadLugarEvaluacion ()));
		}
		else {
			jTextFieldHorasLugarEvaluacion.setText ("0");
		}
	}

	public void calculaFactorTiempoEntrega () {
		if (jRadioButtonEvaluador.isSelected ()) {
			jTextFieldFactorTiempoEntrega.setText (String.valueOf (1));
		}
		else {
			if (jTextFieldHorasTamañoSoftware.getText ().equals ("") || jTextFieldHorasTamañoSoftware.getText ().equals ("0")) {
				jTextFieldFactorTiempoEntrega.setText ("1");
			}
			else {

				if ((Integer.parseInt (jTextFieldHorasTamañoSoftware.getText ()) == 40) && jRadioButtonEmpresa.isSelected ()) {
					jTextFieldFactorTiempoEntrega.setText (String.valueOf (1 + vme.getPorcentajePorPeriodoEntregaVelozSoftwarePequeño ()));
				}
				if ((Integer.parseInt (jTextFieldHorasTamañoSoftware.getText ()) == 65) && jRadioButtonEmpresa.isSelected ()) {
					jTextFieldFactorTiempoEntrega.setText (String.valueOf (1 + vme.getPorcentajePorPeriodoEntregaVelozSoftwareGrande ()));
				}
				if ((Integer.parseInt (jTextFieldHorasTamañoSoftware.getText ()) > 65) && jRadioButtonEmpresa.isSelected ()) {
					jTextFieldFactorTiempoEntrega.setText (String.valueOf (1 + vme.getPorcentajePorPeriodoEntregaVelozSoftwareGrande ()));
				}
			}
		}
	}

	public void setVista (VistaPrincipal vista) {
		this.vista = vista;
	}

	public void recalcular () {
		calculaHorasTamañoSoftware ();
		calculaHorasUsuariosEvaluadores ();
		calculaHorasLugarEvaluacion ();
		calculaFactorTiempoEntrega ();
	}

	public void cambioSeleccionTamañoSoftware (int radioButton) {
		switch (radioButton) {
			case 0: {
				jRadioButtonTamañoSoftwarePequeño.setSelected (true);
				break;
			}
			case 1: {
				jRadioButtonTamañoSoftwareMedio.setSelected (true);
				break;
			}
			case 2: {
				jRadioButtonTamañoSoftwareGrande.setSelected (true);
				break;
			}
			default: {
				break;
			}
		}
	}

//////////////Estas funciones son para guardar los datos en un archivo//////////
	public int retornarTamaño () {
		int tamaño = -1;
		if (jRadioButtonTamañoSoftwarePequeño.isSelected ()) {
			tamaño = 1;
		}
		if (jRadioButtonTamañoSoftwareMedio.isSelected ()) {
			tamaño = 2;
		}
		if (jRadioButtonTamañoSoftwareGrande.isSelected ()) {
			tamaño = 3;
		}
		return tamaño;
	}

	public String retornarModulos () {
		String ModulosPequeños, ModulosMedianos, Modulos;
		ModulosPequeños = jTextFieldNumeroModulosPequeños.getText ().toString ();
		ModulosMedianos = jTextFieldNumeroModulosMedianos.getText ().toString ();
		if (ModulosPequeños.equals ("")) {
			ModulosPequeños = "-1";
		}
		if (ModulosMedianos.equals ("")) {
			ModulosMedianos = "-1";
		}
		Modulos = ModulosPequeños + "#" + ModulosMedianos;
		return Modulos;
	}

	public String retornarUsuarios () {
		String UCE, UNCE, UEX, SUMA, total;
		UCE = jTextFieldUCE.getText ().toString ();
		UNCE = jTextFieldUNCE.getText ().toString ();
		UEX = jTextFieldUEX.getText ().toString ();
		SUMA = jTextFieldTotalUsuarios.getText ().toString ();

		if (UCE.equals ("")) {
			UCE = "-1";
		}
		if (UNCE.equals ("")) {
			UNCE = "-1";
		}
		if (UEX.equals ("")) {
			UEX = "-1";
		}
		total = UCE + "#" + UNCE + "#" + UEX + "#" + SUMA;
		return total;
	}

	public int retornarLugar () {
		int lugar = -1;
		if (jRadioButtonLugarEmpresa.isSelected ()) {
			lugar = 0;
		}
		if (jRadioButtonLugarArrendado.isSelected ()) {
			lugar = 1;
		}
		return lugar;
	}

	public String retornarTiempos () {
		String tiempo, HorasTamaño, HorasUsuarios, HorasLugar;
		HorasTamaño = jTextFieldHorasTamañoSoftware.getText ().toString ();
		HorasUsuarios = jTextFieldHorasUsuariosEvaluadores.getText ().toString ();
		HorasLugar = jTextFieldHorasLugarEvaluacion.getText ().toString ();
		if (HorasTamaño.equals ("")) {
			HorasTamaño = "-1";
		}
		if (HorasUsuarios.equals ("")) {
			HorasUsuarios = "-1";
		}
		if (HorasLugar.equals ("")) {
			HorasLugar = "-1";
		}
		tiempo = HorasTamaño + "#" + HorasUsuarios + "#" + HorasLugar;
		return tiempo;
	}

	public String retornarPeriodo () {
		String periodo, tipo = "-1", DiasEvaluador, DiasEmpresa, Factor;

		if (jRadioButtonEvaluador.isSelected ()) {
			tipo = "0";
		}
		if (jRadioButtonEmpresa.isSelected ()) {
			tipo = "1";
		}

		DiasEvaluador = jTextFieldDiasEvaluador.getText ().toString ();
		DiasEmpresa = jTextFieldDiasEmpresa.getText ().toString ();
		Factor = jTextFieldFactorTiempoEntrega.getText ().toString ();

		if (DiasEvaluador.equals ("")) {
			DiasEvaluador = "-1";
		}
		if (DiasEmpresa.equals ("")) {
			DiasEmpresa = "-1";
		}
		periodo = tipo + "#" + DiasEvaluador + "#" + DiasEmpresa + "#" + Factor;

		return periodo;
	}


        //Métodos para ABRIR y para LIMPIAR
        public void setTamañoSoftwarePequeño(boolean opcion){
            this.jRadioButtonTamañoSoftwarePequeño.setSelected(opcion);
        }

        public void setTamañoSoftwareMedio(boolean opcion){
            this.jRadioButtonTamañoSoftwareMedio.setSelected(opcion);
        }

        public void setTamañoSoftwareGrande(boolean opcion){
            this.jRadioButtonTamañoSoftwareGrande.setSelected(opcion);
        }

        public void setLugarEmpresa(boolean opcion){
            this.jRadioButtonLugarEmpresa.setSelected(opcion);
        }

        public void setLugarArrendado(boolean opcion){
            this.jRadioButtonLugarArrendado.setSelected(opcion);
        }
        
        public void setNumeroModulosPequeños(String valor){
            this.jTextFieldNumeroModulosPequeños.setText(valor);
        }
        
        public void setNumeroModulosMedianos(String valor){
            this.jTextFieldNumeroModulosMedianos.setText(valor);
        }
        
        public void setHorasTamañoSoftware(String valor){
            this.jTextFieldHorasTamañoSoftware.setText(valor);
        }
        
        public void setHorasUsuariosEvaluadores(String valor){
            this.jTextFieldHorasUsuariosEvaluadores.setText(valor);
        }

        public void setHorasLugarEvaluacion(String valor){
            this.jTextFieldHorasLugarEvaluacion.setText(valor);
        }

        public void setUCE(String valor){
            this.jTextFieldUCE.setText(valor);
        }

        public void setUNCE(String valor){
            this.jTextFieldUNCE.setText(valor);
        }

        public void setUEX(String valor){
            this.jTextFieldUEX.setText(valor);
        }

        public void setTotalUsuarios(String valor){
            this.jTextFieldTotalUsuarios.setText(valor);
        }

        public void setDiasEvaluador(String valor){
            this.jTextFieldDiasEvaluador.setText(valor);
        }

        public void setDiasEmpresa(String valor){
            this.jTextFieldDiasEmpresa.setText(valor);
        }

        public void setFactorTiempoEntrega(String valor){
            this.jTextFieldFactorTiempoEntrega.setText(valor);
        }

        public void setEvaluador(boolean opcion){
            this.jRadioButtonEvaluador.setSelected(opcion);
        }

        public void setEmpresa(boolean opcion){
            this.jRadioButtonEmpresa.setSelected(opcion);
        }

	public JRadioButton getjRadioButtonEvaluador () {
		return jRadioButtonEvaluador;
	}

	public JRadioButton getjRadioButtonTamañoSoftwareGrande () {
		return jRadioButtonTamañoSoftwareGrande;
	}

	public JRadioButton getjRadioButtonTamañoSoftwareMedio () {
		return jRadioButtonTamañoSoftwareMedio;
	}

	public JRadioButton getjRadioButtonTamañoSoftwarePequeño () {
		return jRadioButtonTamañoSoftwarePequeño;
	}

	public JTextField getjTextFieldDiasEmpresa () {
		return jTextFieldDiasEmpresa;
	}

	public JTextField getjTextFieldDiasEvaluador () {
		return jTextFieldDiasEvaluador;
	}

	public JTextField getjTextFieldHorasLugarEvaluacion () {
		return jTextFieldHorasLugarEvaluacion;
	}

	public JTextField getjTextFieldNumeroModulosMedianos () {
		return jTextFieldNumeroModulosMedianos;
	}

	public JTextField getjTextFieldNumeroModulosPequeños () {
		return jTextFieldNumeroModulosPequeños;
	}

	public JTextField getjTextFieldUCE () {
		return jTextFieldUCE;
	}

	public JTextField getjTextFieldUEX () {
		return jTextFieldUEX;
	}

	public JTextField getjTextFieldUNCE () {
		return jTextFieldUNCE;
	}

		

	/** This method is called from within the constructor to
	 * initialize the form.
	 * WARNING: Do NOT modify this code. The content of this method is
	 * always regenerated by the Form Editor.
	 */
	@SuppressWarnings ("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        buttonGroupTamañoSoftware = new javax.swing.ButtonGroup();
        buttonGroupLugarEvaluacion = new javax.swing.ButtonGroup();
        buttonGroupModalidadPeriodoEntrega = new javax.swing.ButtonGroup();
        jPanelTamañoSoftware = new javax.swing.JPanel();
        jRadioButtonTamañoSoftwarePequeño = new javax.swing.JRadioButton();
        jRadioButtonTamañoSoftwareMedio = new javax.swing.JRadioButton();
        jRadioButtonTamañoSoftwareGrande = new javax.swing.JRadioButton();
        jLabelPrecisarNumeroModulos = new javax.swing.JLabel();
        jButtonDefinirTamañoSoftware = new javax.swing.JButton();
        jLabelNumeroModulosMedianos = new javax.swing.JLabel();
        jLabelNumeroModulosPequeños = new javax.swing.JLabel();
        jTextFieldNumeroModulosPequeños = new javax.swing.JTextField();
        jTextFieldNumeroModulosMedianos = new javax.swing.JTextField();
        jPanelModalidadUsuariosEvaluadores = new javax.swing.JPanel();
        jLabelTotalUsuarios = new javax.swing.JLabel();
        jLabelUEX = new javax.swing.JLabel();
        jLabelUNCE = new javax.swing.JLabel();
        jLabelUCE = new javax.swing.JLabel();
        jTextFieldUCE = new javax.swing.JTextField();
        jTextFieldUNCE = new javax.swing.JTextField();
        jTextFieldUEX = new javax.swing.JTextField();
        jTextFieldTotalUsuarios = new javax.swing.JTextField();
        jPanelLugarEvaluacion = new javax.swing.JPanel();
        jRadioButtonLugarEmpresa = new javax.swing.JRadioButton();
        jRadioButtonLugarArrendado = new javax.swing.JRadioButton();
        jPanelModalidadPeriodoEntrega = new javax.swing.JPanel();
        jRadioButtonEvaluador = new javax.swing.JRadioButton();
        jRadioButtonEmpresa = new javax.swing.JRadioButton();
        jLabelDiasEvaluador = new javax.swing.JLabel();
        jLabelDiasEmpresa = new javax.swing.JLabel();
        jTextFieldDiasEvaluador = new javax.swing.JTextField();
        jTextFieldDiasEmpresa = new javax.swing.JTextField();
        jLabelFactorTiempoEntrega = new javax.swing.JLabel();
        jTextFieldFactorTiempoEntrega = new javax.swing.JTextField();
        jPanelTiempoEmplear = new javax.swing.JPanel();
        jLabelHorasTamañoSoftware = new javax.swing.JLabel();
        jLabelHorasUsuariosEvaluadores = new javax.swing.JLabel();
        jLabelHorasLugarEvaluacion = new javax.swing.JLabel();
        jTextFieldHorasTamañoSoftware = new javax.swing.JTextField();
        jTextFieldHorasUsuariosEvaluadores = new javax.swing.JTextField();
        jTextFieldHorasLugarEvaluacion = new javax.swing.JTextField();

        setMaximumSize(new java.awt.Dimension(595, 540));
        setMinimumSize(new java.awt.Dimension(595, 540));
        setPreferredSize(new java.awt.Dimension(595, 540));

        jPanelTamañoSoftware.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Tamaño del software"));
        jPanelTamañoSoftware.setMaximumSize(new java.awt.Dimension(292, 200));
        jPanelTamañoSoftware.setMinimumSize(new java.awt.Dimension(292, 200));

        buttonGroupTamañoSoftware.add(jRadioButtonTamañoSoftwarePequeño);
        jRadioButtonTamañoSoftwarePequeño.setText("Pequeño");
        jRadioButtonTamañoSoftwarePequeño.addItemListener(new java.awt.event.ItemListener() {
            public void itemStateChanged(java.awt.event.ItemEvent evt) {
                cambioTamañoSoftware(evt);
            }
        });
        jRadioButtonTamañoSoftwarePequeño.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jRadioButtonTamañoSoftwarePequeñoActionPerformed(evt);
            }
        });

        buttonGroupTamañoSoftware.add(jRadioButtonTamañoSoftwareMedio);
        jRadioButtonTamañoSoftwareMedio.setText("Medio");
        jRadioButtonTamañoSoftwareMedio.addItemListener(new java.awt.event.ItemListener() {
            public void itemStateChanged(java.awt.event.ItemEvent evt) {
                cambioTamañoSoftware(evt);
            }
        });

        buttonGroupTamañoSoftware.add(jRadioButtonTamañoSoftwareGrande);
        jRadioButtonTamañoSoftwareGrande.setText("Grande");
        jRadioButtonTamañoSoftwareGrande.addItemListener(new java.awt.event.ItemListener() {
            public void itemStateChanged(java.awt.event.ItemEvent evt) {
                cambioTamañoSoftware(evt);
            }
        });

        jLabelPrecisarNumeroModulos.setText("Software Grande debe precisar el número de módulos:");

        jButtonDefinirTamañoSoftware.setText("Ayúdame a definir el tamaño");
        jButtonDefinirTamañoSoftware.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButtonDefinirTamañoSoftwareActionPerformed(evt);
            }
        });

        jLabelNumeroModulosMedianos.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        jLabelNumeroModulosMedianos.setText("Número de módulos medianos:");

        jLabelNumeroModulosPequeños.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        jLabelNumeroModulosPequeños.setText("Número de módulos pequeños:");

        jTextFieldNumeroModulosPequeños.setToolTipText("Ingrese un número entero positivo");
        jTextFieldNumeroModulosPequeños.setEnabled(false);
        jTextFieldNumeroModulosPequeños.setPreferredSize(new java.awt.Dimension(100, 20));
        jTextFieldNumeroModulosPequeños.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldNumeroModulosPequeñosKeyReleased(evt);
            }
        });

        jTextFieldNumeroModulosMedianos.setToolTipText("Ingrese un número entero positivo");
        jTextFieldNumeroModulosMedianos.setEnabled(false);
        jTextFieldNumeroModulosMedianos.setPreferredSize(new java.awt.Dimension(100, 20));
        jTextFieldNumeroModulosMedianos.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldNumeroModulosMedianosKeyReleased(evt);
            }
        });

        javax.swing.GroupLayout jPanelTamañoSoftwareLayout = new javax.swing.GroupLayout(jPanelTamañoSoftware);
        jPanelTamañoSoftware.setLayout(jPanelTamañoSoftwareLayout);
        jPanelTamañoSoftwareLayout.setHorizontalGroup(
            jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelTamañoSoftwareLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabelPrecisarNumeroModulos)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanelTamañoSoftwareLayout.createSequentialGroup()
                        .addGroup(jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(jLabelNumeroModulosMedianos, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jLabelNumeroModulosPequeños, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addGap(12, 12, 12)
                        .addGroup(jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(jTextFieldNumeroModulosPequeños, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jTextFieldNumeroModulosMedianos, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addGroup(jPanelTamañoSoftwareLayout.createSequentialGroup()
                        .addGroup(jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                            .addComponent(jRadioButtonTamañoSoftwareGrande, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jRadioButtonTamañoSoftwareMedio, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jRadioButtonTamañoSoftwarePequeño, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addGap(24, 24, 24)
                        .addComponent(jButtonDefinirTamañoSoftware)))
                .addContainerGap())
        );
        jPanelTamañoSoftwareLayout.setVerticalGroup(
            jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelTamañoSoftwareLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jRadioButtonTamañoSoftwarePequeño)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jRadioButtonTamañoSoftwareMedio)
                    .addComponent(jButtonDefinirTamañoSoftware))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jRadioButtonTamañoSoftwareGrande)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jLabelPrecisarNumeroModulos)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelNumeroModulosPequeños)
                    .addComponent(jTextFieldNumeroModulosPequeños, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelTamañoSoftwareLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelNumeroModulosMedianos, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jTextFieldNumeroModulosMedianos, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        jPanelModalidadUsuariosEvaluadores.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Modalidad de Usuarios Evaluadores"));
        jPanelModalidadUsuariosEvaluadores.setMaximumSize(new java.awt.Dimension(292, 169));
        jPanelModalidadUsuariosEvaluadores.setMinimumSize(new java.awt.Dimension(292, 169));

        jLabelTotalUsuarios.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        jLabelTotalUsuarios.setText("Total de Usuarios:");

        jLabelUEX.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        jLabelUEX.setText("UEX:");
        jLabelUEX.setToolTipText("Usuarios Externos");

        jLabelUNCE.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        jLabelUNCE.setText("UNCE:");
        jLabelUNCE.setToolTipText("Usuarios No Comprometidos por la Empresa");

        jLabelUCE.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
        jLabelUCE.setText("UCE:");
        jLabelUCE.setToolTipText("Usuarios Comprometidos por la Empresa");

        jTextFieldUCE.setToolTipText("Ingrese un número entero positivo");
        jTextFieldUCE.setPreferredSize(new java.awt.Dimension(100, 20));
        jTextFieldUCE.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldUCEKeyReleased(evt);
            }
        });

        jTextFieldUNCE.setToolTipText("Ingrese un número entero positivo");
        jTextFieldUNCE.setPreferredSize(new java.awt.Dimension(100, 20));
        jTextFieldUNCE.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldUNCEKeyReleased(evt);
            }
        });

        jTextFieldUEX.setToolTipText("Ingrese un número entero positivo");
        jTextFieldUEX.setPreferredSize(new java.awt.Dimension(100, 20));
        jTextFieldUEX.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                jTextFieldUEXKeyReleased(evt);
            }
        });

        jTextFieldTotalUsuarios.setEnabled(false);
        jTextFieldTotalUsuarios.setPreferredSize(new java.awt.Dimension(100, 20));

        javax.swing.GroupLayout jPanelModalidadUsuariosEvaluadoresLayout = new javax.swing.GroupLayout(jPanelModalidadUsuariosEvaluadores);
        jPanelModalidadUsuariosEvaluadores.setLayout(jPanelModalidadUsuariosEvaluadoresLayout);
        jPanelModalidadUsuariosEvaluadoresLayout.setHorizontalGroup(
            jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createSequentialGroup()
                        .addComponent(jLabelUCE, javax.swing.GroupLayout.PREFERRED_SIZE, 107, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jTextFieldUCE, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createSequentialGroup()
                        .addComponent(jLabelUNCE, javax.swing.GroupLayout.PREFERRED_SIZE, 107, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jTextFieldUNCE, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createSequentialGroup()
                        .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(jLabelTotalUsuarios, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jLabelUEX, javax.swing.GroupLayout.DEFAULT_SIZE, 107, Short.MAX_VALUE))
                        .addGap(18, 18, 18)
                        .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jTextFieldTotalUsuarios, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jTextFieldUEX, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addContainerGap(45, Short.MAX_VALUE))
        );
        jPanelModalidadUsuariosEvaluadoresLayout.setVerticalGroup(
            jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelUCE)
                    .addComponent(jTextFieldUCE, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelUNCE)
                    .addComponent(jTextFieldUNCE, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelUEX)
                    .addComponent(jTextFieldUEX, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelModalidadUsuariosEvaluadoresLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelTotalUsuarios)
                    .addComponent(jTextFieldTotalUsuarios, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(15, Short.MAX_VALUE))
        );

        jPanelLugarEvaluacion.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Lugar de Evaluación"));
        jPanelLugarEvaluacion.setMaximumSize(new java.awt.Dimension(279, 89));
        jPanelLugarEvaluacion.setMinimumSize(new java.awt.Dimension(279, 89));

        buttonGroupLugarEvaluacion.add(jRadioButtonLugarEmpresa);
        jRadioButtonLugarEmpresa.setText("Lugar Empresa");
        jRadioButtonLugarEmpresa.addItemListener(new java.awt.event.ItemListener() {
            public void itemStateChanged(java.awt.event.ItemEvent evt) {
                cambioLugarEvaluacion(evt);
            }
        });

        buttonGroupLugarEvaluacion.add(jRadioButtonLugarArrendado);
        jRadioButtonLugarArrendado.setText("Lugar Arrendado");
        jRadioButtonLugarArrendado.addItemListener(new java.awt.event.ItemListener() {
            public void itemStateChanged(java.awt.event.ItemEvent evt) {
                cambioLugarEvaluacion(evt);
            }
        });

        javax.swing.GroupLayout jPanelLugarEvaluacionLayout = new javax.swing.GroupLayout(jPanelLugarEvaluacion);
        jPanelLugarEvaluacion.setLayout(jPanelLugarEvaluacionLayout);
        jPanelLugarEvaluacionLayout.setHorizontalGroup(
            jPanelLugarEvaluacionLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelLugarEvaluacionLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelLugarEvaluacionLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addComponent(jRadioButtonLugarEmpresa, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jRadioButtonLugarArrendado, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap(154, Short.MAX_VALUE))
        );
        jPanelLugarEvaluacionLayout.setVerticalGroup(
            jPanelLugarEvaluacionLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelLugarEvaluacionLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jRadioButtonLugarEmpresa)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jRadioButtonLugarArrendado)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanelModalidadPeriodoEntrega.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Modalidad Período de Entrega"));
        jPanelModalidadPeriodoEntrega.setMaximumSize(new java.awt.Dimension(279, 94));
        jPanelModalidadPeriodoEntrega.setMinimumSize(new java.awt.Dimension(279, 94));

        buttonGroupModalidadPeriodoEntrega.add(jRadioButtonEvaluador);
        jRadioButtonEvaluador.setText("Evaluador");
        jRadioButtonEvaluador.addItemListener(new java.awt.event.ItemListener() {
            public void itemStateChanged(java.awt.event.ItemEvent evt) {
                CambioPeriodoEntrega(evt);
            }
        });

        buttonGroupModalidadPeriodoEntrega.add(jRadioButtonEmpresa);
        jRadioButtonEmpresa.setText("Empresa");
        jRadioButtonEmpresa.addItemListener(new java.awt.event.ItemListener() {
            public void itemStateChanged(java.awt.event.ItemEvent evt) {
                CambioPeriodoEntrega(evt);
            }
        });

        jLabelDiasEvaluador.setText("Días");

        jLabelDiasEmpresa.setText("Días");

        jTextFieldDiasEvaluador.setToolTipText("Ingrese un número entero positivo");
        jTextFieldDiasEvaluador.setEnabled(false);
        jTextFieldDiasEvaluador.setPreferredSize(new java.awt.Dimension(100, 20));

        jTextFieldDiasEmpresa.setToolTipText("Ingrese un número entero positivo");
        jTextFieldDiasEmpresa.setEnabled(false);
        jTextFieldDiasEmpresa.setPreferredSize(new java.awt.Dimension(100, 20));

        jLabelFactorTiempoEntrega.setText("Factor tiempo de entrega:");

        jTextFieldFactorTiempoEntrega.setText("1");
        jTextFieldFactorTiempoEntrega.setEnabled(false);

        javax.swing.GroupLayout jPanelModalidadPeriodoEntregaLayout = new javax.swing.GroupLayout(jPanelModalidadPeriodoEntrega);
        jPanelModalidadPeriodoEntrega.setLayout(jPanelModalidadPeriodoEntregaLayout);
        jPanelModalidadPeriodoEntregaLayout.setHorizontalGroup(
            jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelModalidadPeriodoEntregaLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(jPanelModalidadPeriodoEntregaLayout.createSequentialGroup()
                        .addGroup(jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(jRadioButtonEmpresa, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                            .addComponent(jRadioButtonEvaluador, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addGap(26, 26, 26)
                        .addGroup(jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                            .addComponent(jTextFieldDiasEvaluador, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jTextFieldDiasEmpresa, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addGroup(jPanelModalidadPeriodoEntregaLayout.createSequentialGroup()
                        .addComponent(jLabelFactorTiempoEntrega, javax.swing.GroupLayout.PREFERRED_SIZE, 142, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jTextFieldFactorTiempoEntrega)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabelDiasEmpresa)
                    .addComponent(jLabelDiasEvaluador))
                .addContainerGap(28, Short.MAX_VALUE))
        );
        jPanelModalidadPeriodoEntregaLayout.setVerticalGroup(
            jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelModalidadPeriodoEntregaLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jRadioButtonEvaluador)
                    .addComponent(jLabelDiasEvaluador)
                    .addComponent(jTextFieldDiasEvaluador, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jRadioButtonEmpresa)
                    .addComponent(jLabelDiasEmpresa)
                    .addComponent(jTextFieldDiasEmpresa, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelModalidadPeriodoEntregaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jTextFieldFactorTiempoEntrega, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabelFactorTiempoEntrega))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanelTiempoEmplear.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(), "Tiempo a Emplear"));
        jPanelTiempoEmplear.setMaximumSize(new java.awt.Dimension(279, 130));
        jPanelTiempoEmplear.setMinimumSize(new java.awt.Dimension(279, 130));

        jLabelHorasTamañoSoftware.setText("Horas por Tamaño Software:");

        jLabelHorasUsuariosEvaluadores.setText("Horas por Usuarios Evaluadores:");

        jLabelHorasLugarEvaluacion.setText("Horas por Lugar de Evaluación:");

        jTextFieldHorasTamañoSoftware.setToolTipText("Ingrese un número entero positivo");
        jTextFieldHorasTamañoSoftware.setEnabled(false);
        jTextFieldHorasTamañoSoftware.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldHorasUsuariosEvaluadores.setToolTipText("Ingrese un número entero positivo");
        jTextFieldHorasUsuariosEvaluadores.setEnabled(false);
        jTextFieldHorasUsuariosEvaluadores.setPreferredSize(new java.awt.Dimension(80, 20));

        jTextFieldHorasLugarEvaluacion.setToolTipText("Ingrese un número entero positivo");
        jTextFieldHorasLugarEvaluacion.setEnabled(false);
        jTextFieldHorasLugarEvaluacion.setPreferredSize(new java.awt.Dimension(80, 20));

        javax.swing.GroupLayout jPanelTiempoEmplearLayout = new javax.swing.GroupLayout(jPanelTiempoEmplear);
        jPanelTiempoEmplear.setLayout(jPanelTiempoEmplearLayout);
        jPanelTiempoEmplearLayout.setHorizontalGroup(
            jPanelTiempoEmplearLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelTiempoEmplearLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelTiempoEmplearLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jLabelHorasLugarEvaluacion, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jLabelHorasTamañoSoftware, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jLabelHorasUsuariosEvaluadores, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelTiempoEmplearLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jTextFieldHorasUsuariosEvaluadores, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldHorasTamañoSoftware, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jTextFieldHorasLugarEvaluacion, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanelTiempoEmplearLayout.setVerticalGroup(
            jPanelTiempoEmplearLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelTiempoEmplearLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelTiempoEmplearLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelHorasTamañoSoftware)
                    .addComponent(jTextFieldHorasTamañoSoftware, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelTiempoEmplearLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelHorasUsuariosEvaluadores)
                    .addComponent(jTextFieldHorasUsuariosEvaluadores, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelTiempoEmplearLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabelHorasLugarEvaluacion)
                    .addComponent(jTextFieldHorasLugarEvaluacion, javax.swing.GroupLayout.PREFERRED_SIZE, 20, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanelModalidadUsuariosEvaluadores, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanelTamañoSoftware, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanelModalidadPeriodoEntrega, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanelLugarEvaluacion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jPanelTiempoEmplear, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jPanelLugarEvaluacion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jPanelTiempoEmplear, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jPanelModalidadPeriodoEntrega, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jPanelTamañoSoftware, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(jPanelModalidadUsuariosEvaluadores, 0, 150, Short.MAX_VALUE)))
                .addContainerGap(173, Short.MAX_VALUE))
        );
    }// </editor-fold>//GEN-END:initComponents

	private void jButtonDefinirTamañoSoftwareActionPerformed (java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButtonDefinirTamañoSoftwareActionPerformed
		DialogoMetodoMPF dialogoTamañoSoftware = new DialogoMetodoMPF (vista, true);
		dialogoTamañoSoftware.setVisible (true);
	}//GEN-LAST:event_jButtonDefinirTamañoSoftwareActionPerformed

        private void cambioTamañoSoftware(java.awt.event.ItemEvent evt) {//GEN-FIRST:event_cambioTamañoSoftware
			if (evt.getStateChange () == ItemEvent.SELECTED) {
				if (!cambioTamañoSoftware) {
					cambioTamañoSoftware = true;
					barraProgreso.setValue (barraProgreso.getValue () + 1);
				}

				int valorBarra = vista.getjProgressBarPaso1 ().getValue ();
				if (jRadioButtonTamañoSoftwareGrande.isSelected ()) {
					jTextFieldNumeroModulosPequeños.setEnabled (true);
					jTextFieldNumeroModulosMedianos.setEnabled (true);
					if (!jTextFieldNumeroModulosPequeños.getText ().equals ("")) {
						valorBarra++;
					}

					if (!jTextFieldNumeroModulosMedianos.getText ().equals ("")) {
						valorBarra++;
					}

					barraProgreso.setMaximum (9);
					barraProgreso.setValue (valorBarra);
					TimingUtils.showTimedBalloon (new BalloonTip (jTextFieldNumeroModulosPequeños, "Recuerde ingresar estos valores",
																  new MinimalBalloonStyle (new Color (231, 225, 165), 2), BalloonTip.Orientation.LEFT_ABOVE,
																  BalloonTip.AttachLocation.SOUTHEAST, 20, 10, false), 3000);
				}
				else {
					if (!jTextFieldNumeroModulosPequeños.getText ().equals ("")) {
						valorBarra--;
					}

					if (!jTextFieldNumeroModulosMedianos.getText ().equals ("")) {
						valorBarra--;
					}

					jTextFieldNumeroModulosPequeños.setEnabled (false);
					jTextFieldNumeroModulosMedianos.setEnabled (false);
					barraProgreso.setMaximum (7);
					barraProgreso.setValue (valorBarra);
				}

				calculaHorasTamañoSoftware ();
				calculaFactorTiempoEntrega ();

			}
        }//GEN-LAST:event_cambioTamañoSoftware

        private void cambioLugarEvaluacion(java.awt.event.ItemEvent evt) {//GEN-FIRST:event_cambioLugarEvaluacion
			if (!cambioLugarEvaluacion) {
				cambioLugarEvaluacion = true;
				barraProgreso.setValue (barraProgreso.getValue () + 1);
			}

			calculaHorasLugarEvaluacion ();
        }//GEN-LAST:event_cambioLugarEvaluacion

        private void CambioPeriodoEntrega(java.awt.event.ItemEvent evt) {//GEN-FIRST:event_CambioPeriodoEntrega
			if (evt.getStateChange () == ItemEvent.SELECTED) {
				if (!cambioPeriodoEntrega) {
					cambioPeriodoEntrega = true;
					barraProgreso.setValue (barraProgreso.getValue () + 1);
				}

				if (jRadioButtonEmpresa.isSelected ()) {
					jTextFieldDiasEmpresa.setEnabled (true);
					jTextFieldDiasEvaluador.setEnabled (false);
					if (!jTextFieldDiasEvaluador.getText ().equals ("")) {
						barraProgreso.setValue (barraProgreso.getValue () - 1);
					}

					if (!jTextFieldDiasEmpresa.getText ().equals ("")) {
						barraProgreso.setValue (barraProgreso.getValue () + 1);
					}

				}
				else {
					jTextFieldDiasEmpresa.setEnabled (false);
					jTextFieldDiasEvaluador.setEnabled (true);
					if (!jTextFieldDiasEvaluador.getText ().equals ("")) {
						barraProgreso.setValue (barraProgreso.getValue () + 1);
					}

					if (!jTextFieldDiasEmpresa.getText ().equals ("")) {
						barraProgreso.setValue (barraProgreso.getValue () - 1);
					}

				}
				calculaFactorTiempoEntrega ();
			}
        }//GEN-LAST:event_CambioPeriodoEntrega

		private void jTextFieldUCEKeyReleased (java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldUCEKeyReleased
			calculaTotalUsuarios ();
		}//GEN-LAST:event_jTextFieldUCEKeyReleased

		private void jTextFieldUNCEKeyReleased (java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldUNCEKeyReleased
			calculaTotalUsuarios ();
			calculaHorasUsuariosEvaluadores ();
		}//GEN-LAST:event_jTextFieldUNCEKeyReleased

		private void jTextFieldUEXKeyReleased (java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldUEXKeyReleased
			calculaTotalUsuarios ();
			calculaHorasUsuariosEvaluadores ();
		}//GEN-LAST:event_jTextFieldUEXKeyReleased

		private void jTextFieldNumeroModulosPequeñosKeyReleased (java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldNumeroModulosPequeñosKeyReleased
			calculaHorasTamañoSoftware ();
			calculaFactorTiempoEntrega ();
		}//GEN-LAST:event_jTextFieldNumeroModulosPequeñosKeyReleased

		private void jTextFieldNumeroModulosMedianosKeyReleased (java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldNumeroModulosMedianosKeyReleased
			calculaHorasTamañoSoftware ();
			calculaFactorTiempoEntrega ();
		}//GEN-LAST:event_jTextFieldNumeroModulosMedianosKeyReleased

                private void jRadioButtonTamañoSoftwarePequeñoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jRadioButtonTamañoSoftwarePequeñoActionPerformed
					// TODO add your handling code here:
                }//GEN-LAST:event_jRadioButtonTamañoSoftwarePequeñoActionPerformed

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.ButtonGroup buttonGroupLugarEvaluacion;
    private javax.swing.ButtonGroup buttonGroupModalidadPeriodoEntrega;
    private javax.swing.ButtonGroup buttonGroupTamañoSoftware;
    private javax.swing.JButton jButtonDefinirTamañoSoftware;
    private javax.swing.JLabel jLabelDiasEmpresa;
    private javax.swing.JLabel jLabelDiasEvaluador;
    private javax.swing.JLabel jLabelFactorTiempoEntrega;
    private javax.swing.JLabel jLabelHorasLugarEvaluacion;
    private javax.swing.JLabel jLabelHorasTamañoSoftware;
    private javax.swing.JLabel jLabelHorasUsuariosEvaluadores;
    private javax.swing.JLabel jLabelNumeroModulosMedianos;
    private javax.swing.JLabel jLabelNumeroModulosPequeños;
    private javax.swing.JLabel jLabelPrecisarNumeroModulos;
    private javax.swing.JLabel jLabelTotalUsuarios;
    private javax.swing.JLabel jLabelUCE;
    private javax.swing.JLabel jLabelUEX;
    private javax.swing.JLabel jLabelUNCE;
    private javax.swing.JPanel jPanelLugarEvaluacion;
    private javax.swing.JPanel jPanelModalidadPeriodoEntrega;
    private javax.swing.JPanel jPanelModalidadUsuariosEvaluadores;
    private javax.swing.JPanel jPanelTamañoSoftware;
    private javax.swing.JPanel jPanelTiempoEmplear;
    private javax.swing.JRadioButton jRadioButtonEmpresa;
    private javax.swing.JRadioButton jRadioButtonEvaluador;
    private javax.swing.JRadioButton jRadioButtonLugarArrendado;
    private javax.swing.JRadioButton jRadioButtonLugarEmpresa;
    private javax.swing.JRadioButton jRadioButtonTamañoSoftwareGrande;
    private javax.swing.JRadioButton jRadioButtonTamañoSoftwareMedio;
    private javax.swing.JRadioButton jRadioButtonTamañoSoftwarePequeño;
    private javax.swing.JTextField jTextFieldDiasEmpresa;
    private javax.swing.JTextField jTextFieldDiasEvaluador;
    private javax.swing.JTextField jTextFieldFactorTiempoEntrega;
    private javax.swing.JTextField jTextFieldHorasLugarEvaluacion;
    private javax.swing.JTextField jTextFieldHorasTamañoSoftware;
    private javax.swing.JTextField jTextFieldHorasUsuariosEvaluadores;
    private javax.swing.JTextField jTextFieldNumeroModulosMedianos;
    private javax.swing.JTextField jTextFieldNumeroModulosPequeños;
    private javax.swing.JTextField jTextFieldTotalUsuarios;
    private javax.swing.JTextField jTextFieldUCE;
    private javax.swing.JTextField jTextFieldUEX;
    private javax.swing.JTextField jTextFieldUNCE;
    // End of variables declaration//GEN-END:variables
}
